package com.personal.controller;

import com.personal.bo.CreateOrderBO;
import com.personal.service.OrderService;
import com.personal.utils.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@RestController
@RequestMapping("/order")
@Api(tags = "订单模块接口")
public class OrderController {

    @Autowired
    private OrderService orderService;

    @PostMapping("/createOrder")
    @ApiOperation("创建订单")
    public Result createOrder(@RequestBody CreateOrderBO createOrderBO){
        return orderService.createOrder(createOrderBO);
    }

}
